GDK W32: Preserve the target value for change_property()
authorРуслан Ижбулатов <lrn1986@gmail.com>
Sun, 26 Nov 2017 00:21:22 +0000 (00:21 +0000)
committerРуслан Ижбулатов <lrn1986@gmail.com>
Sat, 2 Dec 2017 10:38:39 +0000 (10:38 +0000)
commit5e2e0af8b4a39b3174aef4de964d9655d1c7b6ea
treeac3db88bad42e650640f7ad310a23cf34f5efe11
parent44bc05df80cb99a5d3c80afe6323bc859cbc3df2
GDK W32: Preserve the target value for change_property()

We need to know the target atom value to know when we need to
do something with side-effects (since side-effects are expressed via
special target values). Previously, the code side-stepped that by looking
at the data type (which was rather unique for the one side-effect
target that we supported, signalled by the TARGETS target),
but for the DELETE target that seems to be no longer an option, hence the new
field to carry this information past the convert_selection() routine.

This prevents GDK from throwing a warning when trying to convert
a DELETE target, which has no format or data objects set.

The side-effects for the DELETE target happen earlier, in GTK layer.
By the point it gets to change_property(), it's a no-op.

https://bugzilla.gnome.org/show_bug.cgi?id=786509
gdk/win32/gdkdnd-win32.c
gdk/win32/gdkevents-win32.c
gdk/win32/gdkselection-win32.c
gdk/win32/gdkselection-win32.h